package day16.tarena.GUI;
import java.awt.BorderLayout;
import java.awt.GridLayout;
import javax.swing.JFrame;
import javax.swing.JButton;
public class TestGrid {
	public static void main(String[] args) {
		JFrame jf = new JFrame("Test Grid");
		
		GridLayout gl = new GridLayout(5,4);
		for (int i=0; i<20;i++){
			JButton jb = new JButton(i+"");
			jf.add(jb);
		}
		jf.setLayout(gl);
		jf.setLocation(300, 200);
		jf.setSize(300,200);
		jf.setVisible(true);
		jf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
	}

}